/*
 * OPIAM Suite
 *
 * Distributable under LGPL license.
 * See terms of license at gnu.org.
 */

package opiam.admin.faare.service.services.views;

import opiam.admin.faare.persistence.javabeans.JBTop;


/**
 *
 * This class allows to instantiate blocks in the views.<br>
 * These virtual nodes are declared in the views.xml file by the "objectview"
 * element of type="group".<br>
 *
 * Example:<br>
 *         <code>&lt;objectview name="blocs" type="group" labelAtt="name"
 *               size="50" icon="./images/bullet4.gif"/&gt;</code><br>
 *
 */
public class JBGroup extends JBTop
{
    /** Name of the blocks. */
    private String name;

    /** Block index. */
    private int value;

    /** Number of elements to display under each block. */
    private int size;

    /**
     * Returns the name of the blocks.
     *
     * @return The name.
     */
    public String getName()
    {
        return name;
    }

    /**
     * Sets the name.
     *
     * @param aname The name to set.
     */
    public void setName(String aname)
    {
        this.name = aname;
    }

    /**
     * Returns the index of the block.
     *
     * @return The index.
     */
    public int getValue()
    {
        return value;
    }

    /**
     * Sets the index of the block.
     *
     * @param avalue  The value to set.
     */
    public void setValue(int avalue)
    {
        this.value = avalue;
    }

    /**
     * Returns the block size.
     *
     * @return The number.
     */
    public int getSize()
    {
        return size;
    }

    /**
     * Sets the block size.
     *
     * @param asize  The size to set.
     */
    public void setSize(int asize)
    {
        this.size = asize;
    }
}
